﻿#ifndef CAMERA_DEFINE_H
#define CAMERA_DEFINE_H
#include <QObject>

namespace CameraSpace {

struct CameraInfo{
    unsigned char initResult = 0x01;    // 0~255
    unsigned char exposureMode = 0x02;  // 0~255
    unsigned char triggerSource = 0x01; // 0~255
    unsigned short exposureTime = 5000; // 0~65535
    unsigned short frameTime = 1; // 0~65535
    unsigned char analogGain = 11; // 0~255
    unsigned char digitalGain = 40;// 0~255
    unsigned short picStartX = 0; // 0~65535
    unsigned short picWidth = 8424;  // 0~65535
    unsigned short picStartY = 0; // 0~65535
    unsigned short picHeight = 6032; // 0~65535
    unsigned short tempx10 = 200;   // 0~65535
    unsigned char pictureType = 0x02;// 0~255
    unsigned char saveLocation = 0x01;  // 0~255
    unsigned int intStorageSize;
    unsigned int outStorageSize;
};

struct CameraWindow{
    unsigned short picStartX = 0;
    unsigned short picWidth = 8424;
    unsigned short picStartY = 0;
    unsigned short picHeight = 6032;
};

struct PictureInfo{
    unsigned int picIndex;
    unsigned short allLinesCounts;
    unsigned short startLine;
    unsigned short endLine;
    unsigned short lineCounts;
    QByteArray picture;
};

enum CameraMode{
    ShowAndSave        = 0x01,
    OnlyShow           = 0x02
};
enum TriggerSource{
    Internal            = 0x01,
    External            = 0x02
};
enum SaveLocation{
    In              = 0x01,
    Out,
    All
};

enum PictureType{
    Test = 0x1,
    Actual
};
}
#endif // CAMERA_DEFINE_H
